<template>
  <div  class="layout-content-body">
    <player :playList="playList" :isLIve="isLive"></player>
  </div>
</template>
<script>
  import api from '../../api'
  import player from "../../components/player/player.vue"
  export default {
    components: {
      player
    },
    data: function () {
      return {
        playList: [],
        isLive:false
      }
    },
    methods:{
      getall (){
        this.spinShow = true
        api.GetVideoList().then(response => {
          if (response.data.code === 0) {
            this.playList = response.data.Data
//            this.videoOptions.sources[0]=this.playList[0]
          } else {
            this.$Notice.warning({
              title: '数据异常',
              desc: this.msg
            });
          }
        }, error => {
          this.$Notice.warning({
            title: '数据异常',
            desc: this.msg
          });
        })
      },
    },
    mounted (){
      this.getall()
    }
  }
</script>
